package com.jiangsonglin.bootstrapAdmin.autoconfigure;

import org.springframework.context.annotation.Configuration;
import org.springframework.core.annotation.Order;
import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

/**
 * <p>  </p>
 */
@Configuration
@Order(1)
public class BootstrapAdminResourceAutoConfiguration implements WebMvcConfigurer {
    @Override
    public void addResourceHandlers(ResourceHandlerRegistry registry) {
        registry.addResourceHandler("/bsa/**")
                .addResourceLocations("classpath:/static/bootstrap-admin/dist/")
                .setCachePeriod(0); // 可选：设置缓存过期时间（单位秒）
    }
}
